-
as seen on Programmers
- Search for 'Programmers'
Recently I competed in nation wide programming contest finals. Not unexpectedly all problems were algorithmic. I lost (40 points out of 600. Winner got ~300). I know why I lost very well - I don't know how to find actual problem in those obfuscated tasks which are life-blood of every competition.…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I'm trying to implement a genetic algorithm that will calculate the minimum of the Rastrigin functon and I'm having some issues.
I need to represent the chromosome as a binary string and as the Rastrigin's function takes a list of numbers as a parameter, how can decode the chromosome to a list of…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
I am developing a chess program. And have made use of an alpha beta algorithm and a static evaluation function. I have successfully implemented both but I want to improve the evaluation function by automatically tuning the weights assigned to its features. At this point am totally confused about the…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
I'm new to coding , learning it since last year actually.
One of my worst habits is the following:
Often I'm trying to create a solution that is too big , too complex and doesn't achieve what needs to be achieved, when a hacky kludge can make the fit.
One last example was the following (see paste…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
I want to make a solution to find the optimum route of school visit. For example, I want to visit 5 schools (A, B, C, D, E) in my city. Then I must find out what school I should visit first, then the second, then the third etc. with distance, time, and cost criteria. The problem is, I am confused…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
I have taken my major as computer science and Engineering and I am really confused at this moment. My first course was about learning C and C++ and I learned the basics of those. Now I am really confused what to do next.
Some says I should practice algorithms and do contests in ACM-ICPC for now…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
My boss keeps mentioning nonchalantly that bad programmers use break and continue in loops.
I use them all the time because they make sense; let me show you the inspiration:
function verify(object) {
if (object->value < 0) return false;
if (object->value > object->max_value)…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
As far as understand it is a well-established opinion within the C++ community that
C is an obsolete language that was useful 20 years ago but cannot support many modern good programming practices, or even encourages bad practices;
certain features that were typical of C++ (C with classes) during…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
Hi,
I was just wondering if there's any field which concerns the task-control programming (or at least that's the way I call it).
For a better explanation of task-control consider the following scenario:
An application (master-thread) waits for a command - which might be a particular action or…
>>> More
-
as seen on Programmers
- Search for 'Programmers'
I'm writing a simple command line math game, and I'm using python's autodoc for my math algorithms to help me remember, for example, what a proth number is while i'm writing the algorithm, but later on I'll want to tell that information to the user as well, so they'll know what the answer was. So…
>>> More